import Request from "@/common/utils/request/index";
import { GetVariantQuickItemListDTO } from "@/types/model/variantQuickItem/dtos/variantQuickItem.dto";

enum Api {
  GetVariantQuickItemList = "/jeecgboot/posVariantQuickItem/list",
  AddVariantQuickItem = "/jeecgboot/posVariantQuickItem/add",
  EditVariantQuickItem = "/jeecgboot/posVariantQuickItem/edit",
  DeleteVariantQuickItem = "/jeecgboot/posVariantQuickItem/delete",
}

export const getVariantQuickItemList = (params: GetVariantQuickItemListDTO) =>
  Request.getInstance().send({
    url: Api.GetVariantQuickItemList,
    method: "GET",
    params,
  });

export const addVariantQuickItem = (params: any) =>
  Request.getInstance().send({
    url: Api.AddVariantQuickItem,
    method: "POST",
    data: params,
  });

export const editVariantQuickItem = (params: any) =>
  Request.getInstance().send({
    url: Api.EditVariantQuickItem,
    method: "POST",
    params,
  });
export const deleteVariantQuickItem = (params: any) =>
  Request.getInstance().send({
    url: Api.DeleteVariantQuickItem,
    method: "POST",
    params,
  });
